package com.likianta.anykey;

import com.thinkcool.circletextimageview.CircleTextImageView;

/**
 * Created by Likianta_DoDoRa on 2017/11/21 0021.
 */

public class Card {
    
    private String cardGroup = "未分类";
    private String cardTitle; // 卡片标题
    private String cardSummary; // 卡片的摘要内容（摘要=用户名+密码）
    
    // 头像相关
    private String cardHeadText;
    private int cardHeadTextColor;
    private int cardHeadFillColor;
    private int cardHeadResId = 0;
    
    public Card(String cardTitle, String cardSummary, CircleTextImageView cardHead, int resId) {
        new Card(cardTitle, cardSummary, cardHead, resId, "未分类");
    }
    
    public Card(String cardTitle, String cardSummary, CircleTextImageView cardHead, int resId, String cardGroup) {
        this.cardGroup = cardGroup;
        this.cardTitle = cardTitle;
        this.cardSummary = cardSummary;
        if (resId == 0) {
            cardHeadText = cardHead.getTextString();
            cardHeadTextColor = cardHead.getTextColor();
            cardHeadFillColor = cardHead.getFillColor();
        } else {
            cardHeadResId = resId;
        }
    }
    
    public String getCardGroup() {
        return cardGroup;
    }
    
    public void setCardGroup(String cardGroup) {
        this.cardGroup = cardGroup;
    }
    
    public int getCardHeadResId() {
        return cardHeadResId;
    }
    
    public void setCardHeadResId(int cardHeadResId) {
        this.cardHeadResId = cardHeadResId;
    }
    
    public String getCardHeadText() {
        return cardHeadText;
    }
    
    public void setCardHeadText(String cardHeadText) {
        this.cardHeadText = cardHeadText;
    }
    
    public int getCardHeadTextColor() {
        return cardHeadTextColor;
    }
    
    public void setCardHeadTextColor(int cardHeadTextColor) {
        this.cardHeadTextColor = cardHeadTextColor;
    }
    
    public int getCardHeadFillColor() {
        return cardHeadFillColor;
    }
    
    public void setCardHeadFillColor(int cardHeadFillColor) {
        this.cardHeadFillColor = cardHeadFillColor;
    }
    
    public String getCardSummary() {
        return cardSummary;
    }
    
    public void setCardSummary(String cardSummary) {
        this.cardSummary = cardSummary;
    }
    
    public String getCardTitle() {
        return cardTitle;
    }
    
    public void setCardTitle(String cardTitle) {
        this.cardTitle = cardTitle;
    }
    
}
